import Vue from 'vue'
import App from './App.vue'
import router from './router'
import ElementUI from 'element-ui';
import 'element-ui/lib/theme-chalk/index.css';
import axios from 'axios'
import qs from 'qs'
import CollapseTransition from 'element-ui/lib/transitions/collapse-transition';
import '../public/css/ali/iconfont.css'
Vue.config.productionTip = false
Vue.use(ElementUI)

Vue.component(CollapseTransition.name, CollapseTransition)
Vue.prototype.$axios=axios
Vue.prototype.$qs=qs
Vue.filter('time',function(time){
  let date =new Date(time*1000)
  let year =date.getFullYear()
  let mouth=(date.getMonth()+1+"").padStart(2,'0')
  let day=(date.getDate()+'').padStart(2,'0')
  return `${year}-${mouth}-${day}`
})
// Vue.filter("time",function(time){
//   const date=new Date(time*1000)
//   let year=date.getFullYear()
//   let mouth=(date.getMonth()+1+"").padStart(2,'0')
//   let day=(date.getDate()+'').padStart(2,'0').
//   return `${year}-${mouth}-${day}`
// })
Vue.prototype.$api='http://127.0.0.1:1000/'
//Vue.prototype.$api='http://www.5jiahui.xyz:3001/'
new Vue({
  el:'#app',
  router,
  render: h => h(App)
}).$mount('#app')
